<?php include("admin/system/engine.php"); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
  <head>
    <meta http-equiv="content-type" content="text/html; charset=windows-1250" />
    <title><?php echo $website; ?></title>
    <link rel="stylesheet" href="main.css" type="text/css" />
    <link rel="alternate" type="application/rss+xml" title="feed" href="feed.php" />
  </head>
  <body>
    <h1 id="header"><?php echo $website; ?></h1>
    <?php
    while($row = mysql_fetch_object($result)) {
    ?>
      <div id="comic-area">
         <h3><?php chapter(); ?>&gt;<?php getcomic('title') ?></h3>
         <?php comic(); ?>
         <div class="mainNav">
           <ul>
             <li><?php firstPost();?></li>
             <li><?php previousChapter();?></li>
             <li><?php previousPost();?></li>
             <li><?php dropArchive();?></li>
             <li><?php nextPost();?></li>
             <li><?php nextChapter();?></li>
             <li><?php lastPost();?></li>
           </ul>
            <br class="clear" />
         </div>
         <div id="commentsTitle">
            <div class="commentsWidth">
               <?php commentlink("no comments","1 comment","% comments","comment on this comic","close"); ?>
            </div>
         </div>
      </div>
      <div class="comments">
          <?php include('comments.php'); ?>
      </div>
      <?php
      if($c==0) {
      ?>
        <div class="post">
          <?php
          $a_query = "SELECT * FROM ".$prefix."articles WHERE parentid='$row->id' AND status='1' ORDER BY aid DESC";
          $a_result = mysql_query($a_query);
          while($a_row = mysql_fetch_object($a_result)) {
          ?>
            <h2><?php permalink(); ?></h2>
            <p><?php postBody(); ?></p>
            <div class="byline">
              by <?php getauthor("firstname"); ?> on <?php getpostdate(); ?> at <?php getposttime(); ?>
            </div>
          <?php
          }
          ?>
        </div>
      <?php
      }
      ?>
    <?php
    }
    ?>
      <div id="footer" class="clear">
         <p>Powered by <a href="http://someryc.mostpopularcomic.com/">SomeryC</a>.</p>
      </div>
  </body>
</html>
